import requests
from bs4 import BeautifulSoup
url="https://www.baidu.com/"
head={'User-Agent':'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/122.0.0.0 Safari/537.36'}
r=requests.get(url=url,headers=head)
r.encoding=r.apparent_encoding
yuanma=r.text
soup=BeautifulSoup(yuanma,'lxml')
a=soup.select('#su')[0].attrs['value']
print(a)
b=soup.select('input[type="submit"]')[0].attrs['value']
print(b)
c=soup.select('input[id="su"]')[0].attrs['value']
print(c)